<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateRedBookAccountsTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('red_book_accounts', function (Blueprint $table) {
            $table->bigIncrements('id');
            $table->string('username')->comment('账号');
            $table->string('password')->comment('密码');
            $table->boolean('enable')->default(0)->comment('启用');
            $table->dateTime('run_date')->nullable()->comment('最近执行时间');
            $table->string('run_log')->nullable()->comment('最近执行结果');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('red_book_accounts');
    }
}
